Fix gtk_tree_view_get_tooltip_context() transfer annotation
authorMartin Pitt <martin.pitt@ubuntu.com>
Mon, 14 Nov 2011 13:32:32 +0000 (14:32 +0100)
committerMartin Pitt <martin.pitt@ubuntu.com>
Mon, 14 Nov 2011 13:33:51 +0000 (14:33 +0100)
The default (out) transfer mode is "full", but the passed "model" pointer gets
set to gtk_tree_view_get_model() which is "transfer none". This caused Python
programs to free the model after calling this, causing crashes.

gtk/gtktreeview.c

index 016081853c9e496594ac9bd4b9cfb81030c4e648..c1fe4014cc7f9772e2c0a2a1d2a0cdd7a7041740 100644 (file)
@@ -16286,7 +16286,8 @@ gtk_tree_view_set_tooltip_cell (GtkTreeView       *tree_view,
  * @x: (inout): the x coordinate (relative to widget coordinates)
  * @y: (inout): the y coordinate (relative to widget coordinates)
  * @keyboard_tip: whether this is a keyboard tooltip or not
- * @model: (out) (allow-none): a pointer to receive a #GtkTreeModel or %NULL
+ * @model: (out) (allow-none) (transfer none): a pointer to receive a
+ *         #GtkTreeModel or %NULL
  * @path: (out) (allow-none): a pointer to receive a #GtkTreePath or %NULL
  * @iter: (out) (allow-none): a pointer to receive a #GtkTreeIter or %NULL
  *